<?php

interface Connector_interface
{
	public function connect($server, $user, $pass);
	public function is_connected();
	public function disconnect();
	
	public function list_databases();
	public function add_database($name);
	public function remove_database($name);
	public function change_database_name($name);
	public function use_database($name);

	public function list_tables();
	public function add_table($name);
	public function remove_table($name);
	public function change_table_name($name, $newname);
	
	public function list_rows($table);
	public function add_row(); // returns the id for the added row
	public function remove_row($id);
	
	public function list_fields($table);
	public function add_field($table, $name, $type);
	public function remove_field($table, $name);
	public function change_field_type($table, $field, $type);

	public function update_value($id, $field, $value);
}